home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Internet Info 1994 March
/
Internet Info CD-ROM (Walnut Creek) (March 1994).iso
/
answers
/
rec
/
games
/
corewar-faq
< prev
next >
Wrap
Internet Message Format
|
1994-04-06
|
27KB
Path: bloom-beacon.mit.edu!senator-bedfellow.mit.edu!faqserv
From: stst@vuse.vanderbilt.edu (Stefan Strack)
Newsgroups: rec.games.corewar,rec.answers,news.answers
Subject: Core War Frequently Asked Questions (rec.games.corewar FAQ)
Supersedes: <games/corewar-faq_764330571@rtfm.mit.edu>
Followup-To: rec.games.corewar
Date: 6 Apr 1994 11:13:06 GMT
Organization: The Core War Newsletter
Lines: 593
Approved: news-answers-request@MIT.Edu
Expires: 5 May 1994 11:12:37 GMT
Message-ID: <games/corewar-faq_765630757@rtfm.mit.edu>
Reply-To: stst@vuse.vanderbilt.edu (Stefan Strack)
NNTP-Posting-Host: bloom-picayune.mit.edu
Summary: This posting contains a list of Frequently Asked Questions
(and their answers) about the game Core War. It should be
read by anyone interested in posting to the rec.games.corewar
newsgroup or submitting warriors to the ongoing Core War
tournament - KotH.
X-Last-Updated: 1994/01/10
Originator: faqserv@bloom-picayune.MIT.EDU
Xref: bloom-beacon.mit.edu rec.games.corewar:1333 rec.answers:4776 news.answers:17730
Archive-name: games/corewar-faq
Last-modified: 1994/01/03
Version: 2.1.5
These are the Frequently Asked Questions (and answers) from the USENET
newsgroup rec.games.corewar. This FAQ list is also available by anonymous FTP
from rtfm.mit.edu as pub/usenet/news.answers/games/corewar-faq.Z.
TABLE OF CONTENTS Line
------------------------------------------------------------------------
1. What is Core War? 69
2. Is it Core War or Core Wars? 82
3. Where can I find more information about Core War? 90
4. Core War has changed since Dewdney's articles. Where do I get 108
a copy of the current instruction set?
5. What is this ICWS'94? 122
6. What is the ICWS? 138
7. What is TCWN? 148
8. How do I join? 156
9. Are back issues of TCWNs available? 173
10. What is the EBS? 180
11. Where are the Core War archives? 196
12. Where can I find a Core War system for . . . ? 214
13. I do not have ftp. How do I get all of this great stuff? 262
14. I do not have access to Usenet. How do I post and receive news? 269
15. When is the next tournament? 287
16. What is KOTH? How do I enter? 296
17. Is it DAT 0, 0 or DAT #0, #0? How do I compare to core? 440
18. How does SLT (Skip if Less Than) work? 452
19. What does (expression or term of your choice) mean? 464
20. Other questions? 592
---------------------------------------------------------------------
Q 1: What is Core War?
A 1: Core War is a game played by two or more programs (and vicariously
by their authors) written in an assembly language called Redcode and
run in a virtual computer called MARS (for Memory Array Redcode Simulator).
The object of the game is to cause all of the opposing programs to
terminate, leaving your program in sole posession of the machine.
There are Core War systems available for most computer platforms.
Redcode has been standardized by the ICWS, and is therefore transportable
between all standard Core War systems.
----------------------------------------------------------------------
Q 2: Is it "Core War" or "Core Wars"?
A 2: Both terms are used. Early references were to Core War. Later
references seem to use Core Wars. I prefer "Core War" to refer to
the game in general, "core wars" to refer to more than one specific
battle.
----------------------------------------------------------------------
Q 3: Where can I find more information about Core War?
A 3: Core War was first described in the "Core War Guidelines" of March,
1984 by D. G. Jones and A. K. Dewdney of the Department of Computer
Science at The University of Western Ontario (Canada). Dewdney wrote
several "Computer Recreations" articles in "Scientific American" which
discussed Core War, starting with the May 1984 article. Those articles
are contained in an anthology:
Author: Dewdney, A. K.
Title: The Armchair Universe: An Exploration of Computer Worlds
Published: New York: W. H. Freeman (c) 1988
ISBN: 0-7167-1939-8
Library of Congress Call Number: QA76.6 .D517 1988
The Redcode language has changed somewhat since; see Q 4.
---------------------------------------------------------------------
Q 4: Core War has changed since Dewdney's articles. Where do I get a
copy of the current instruction set?
A 4: A draft of the official standard (ICWS'88) is available by anonymous
FTP from the Core War archives (soda.berkeley.edu) as
pub/corewar/documents/standards/redcode-icws-88.Z
This document is formatted awkwardly and contains ambiguous statements. For a
more approachable intro to Redcode, take a look at
pub/corewar/documents/tutorial.1.Z
tutorial.2.Z
(See also Q11)
---------------------------------------------------------------------
Q 5: What is this ICWS'94?
A 5: There is an ongoing discussion about future enhancements to the
Redcode language. A proposed new standard, dubbed ICWS'94, is currently being
evaluated. A major change is the addition of "instruction modifiers" that
allow instructions to modify A-field, B-field or both. Also new is a
post-increment indirect addressing mode and unrestricted opcode and
addressing mode combination ("no illegal instructions"). ICWS'94 is backwards
compatible; i.e. ICWS'88 warriors will run correctly on an ICWS'94 system.
Take a look at the ICWS'94 draft for more information (soda.berkeley.edu
pub/corewar/documents/icws94.draft.Z). You can try out the new standard by
submitting warriors to the experimental '94 KotH server (see Q16).
pMARS, a corewar system that implements ICWS'94 is available at soda (see
Q12).
---------------------------------------------------------------------
Q 6: What is the ICWS?
A 6: About one year after Core War first appeared in Sci-Am, the
"International Core War Society" (ICWS) was established. Since that
time, the ICWS has been responsible for the creation and maintenance
of Core War standards and the running of Core War tournaments. There
have been six annual tournaments and two standards (ICWS'86 and
ICWS'88).
---------------------------------------------------------------------
Q 7: What is TCWN?
A 7: Since March of 1987, "The Core War Newsletter" (TCWN) has been the
official newsletter of the ICWS. It is published quarterly and recent
issues are also available as Encapsulated PostScript on soda.berkeley.edu
(see Q9).
---------------------------------------------------------------------
Q 8: How do I join?
A 8: For more information about joining the ICWS (which includes a
subscription to TCWN), or to contribute an article, review, cartoon, letter,
joke, rumor, etc. to TCWN, please contact:
Jon Newman
13824 NE 87th Street
Redmond, WA 98052-1959
email: jonn@microsoft.com (Note: Microsoft has NO affiliation with
Core War. Jon Newman just happens
to work there, and we want to keep
it that way!)
Current annual dues are $15.00 in US currency.
----------------------------------------------------------------------
Q 9: Are back issues of TCWN available?
A 9: Recent issues can be found on soda.berkeley.edu (see Q11).
Older issues (up to Winter 1991) are also available (see the next TCWN
for details).
---------------------------------------------------------------------
Q10: What is the EBS?
A10: The Electronic Branch Section (EBS) of the ICWS is a group of
Core War enthusiasts with access to electronic mail. There are no fees
associated with being a member of the EBS, and members do reap some of
the benefits of full ICWS membership without the expense. For instance,
the ten best warriors submitted to the EBS tournament are entered
into the annual ICWS tournament. All EBS business is conducted in the
rec.games.corewar newsgroup.
The current goal of the EBS is to be at the forefront of Core War by writing
and implementing new standards and test suites in preparation for the tenth
anniversary of Core War in May of 1994 (see Q 5). Its immediate
business will be to set up a Charter and establish its officers.
----------------------------------------------------------------------
A11: Where is the Core War archive?
Q11: Many documents such as the guidelines and the ICWS standards
along with previous tournament Redcode entries and complete Core War
systems are available via anonymous ftp from soda.berkeley.edu
(128.32.149.19) in the /pub/corewar directories. Also, most of past
rec.games.corewar postings (including Redcode source listings) are
archived there. Jon Blow (blojo@soda.berkeley.edu) is the archive
administrator. When uploading to /pub/corewar/incoming, ask Jon to move
your upload to the appropriate directory and announce it on the net.
Much of what is available on soda is also available on the German archive
at iraun1.ira.uka.de (129.13.10.90) in the /pub/X11/corewars directory.
This FAQ is automatically archived by news.answers. See the header for
the current archive name and news.answers for how to get it.
----------------------------------------------------------------------
Q12: Where can I find a Core War system for . . . ?
A12: Core War systems are available via anonymous ftp from
soda.berkeley.edu in the pub/corewar/systems directory.
Currently, there are Unix X-Window, IBM PC-compatible (sorry, no systems
specifically designed for MS-Windows yet), Macintosh, and Amiga
Core War systems available there.
CAUTION! There are many, many Core War systems available which are NOT
ICWS'88 (or even ICWS'86) compatible available at various archive sites
other than soda.berkeley.edu. Generally, the older the program - the less
likely it will be ICWS compatible.
Reviews of Core War systems would be greatly appreciated in the newsgroup
and in the newsletter.
Below is a not necessarily complete or up-to-date list of what's available
at soda:
MADgic41.lzh - corewar for the Amiga, v4.1
MAD4041.lzh - older version?
MAD50B.lha - corewar for the Amiga, beta version 5.0
Redcoder-10.hqx - corewar for the Mac
core-11.hqx - corewar for the Mac
core-wars-simulator.hqx - same as core-11.hqx?
corewar_unix_x11.tar.Z - corewar for UNIX/X-windows, ICWS'86 but
not ICWS'88 compatible
koth31.tar.Z - corewar for UNIX/X-windows. This program runs the
KotH server at intel.com
koth.shar.Z - older version
kothpc.zip - port of older version of KotH to the PC
deluxe20c.tar.Z - corewar for UNIX (X-windows or curses) and PC
mars.tar.Z - corewar for UNIX, likely not ICWS'88 compatible
icons.zip - corewar icons for MS-Windows
macrored.zip - a redcode macro-preprocessor (PC)
c88v49.zip - PC corewar, textmode display
mars88.zip - PC corewar, graphics mode display
corwp302.zip - PC corewar, textmode display, slowish
mercury2.zip - PC corewar written in assembly, fast!
mtourn11.zip - tournament scheduler for mercury (req. 4DOS)
pmars03s.zip - portable system, ICWS'88 and '94, runs on UNIX,
PC, Mac, Amiga. C source archive
pmars03s.tar.Z - same as above
pmars03.zip - PC executables, graphics display version
macpmars02.sit.hqx - pMARS executable for Mac
ApMARS03.lha - pMARS executable for Amiga
----------------------------------------------------------------------
Q13: I do not have ftp. How do I get all of this great stuff?
A13: There is an ftp email server at ftpmail@decwrl.dec.com. Send
email with a subject and body text of "help" (without the quotes) for
more information on its usage.
----------------------------------------------------------------------
Q14: I do not have access to Usenet. How do I post and receive news?
A14: To receive rec.games.corewar articles by email, join the COREWAR-L
list run on the Stormking.Com ListProcessor. To join, send:
SUB COREWAR-L FirstName LastName
to:
LISTPROC@STORMKING.COM
You can send mail to corewar-l@stormking.com to post even if you are not
a member of the list. Responsible for the listserver is Scott J. Ellentuch
(tuc@stormking.com).
Another server that allows you to post (but not receive) articles is
available. Email your post to rec-games-corewar@cs.utexas.edu and it will be
automatically posted for you.
----------------------------------------------------------------------
Q15: When is the next tournament?
A15: The ICWS holds an annual tournament. Traditionally, the deadline
for entering is the 15th of December.
The EBS usually holds a preliminary tournament around the 15th of November
and sends the top finishers on to the ICWS tournament.
----------------------------------------------------------------------
Q16: What is KOTH? How do I enter?
A16: King Of The Hill (KOTH) is an ongoing Core War tournament available
to anyone with email provided by William Shubert (wms@iwarp.intel.com). You
enter by submitting via email a Redcode program with special comment lines.
You will receive a reply indicating how well your program did against the
current top twenty programs "on the hill". Your program will play 100
battles against each of the 20 other programs currently on the Hill. You
receive 3 points for each win and 1 point for each tie. (The existing
programs do not replay each other, but their previous battles are recalled.)
All scores are updated to reflect your battles and all 21 programs are ranked
from high to low. If you are number 21 you are pushed off the Hill, if you
are higher than 21 someone else is pushed off.
Entry rules for King of the Hill Corewar:
1) Write a corewar program. KotH is fully ICWS '88 compatible, EXCEPT that
a comma (",") is required between two arguments.
2) Put the line ";redcode" at the top of your program. This MUST be the
first line. Anything before it will be lost. If you wish to receive
mail on every new entrant, use ";redcode verbose". Otherwise you will
only receive mail if a challenger makes it onto the hill. Use
";redcode quiet" if you wish to receive mail only when you get shoved
off the hill. (Also, see 5 below).
Additionally, adding ";name <program name>" and ";author <your name>"
will be helpful in the performance reports. Do NOT have a line
beginning with ";address" in your code; this will confuse the mail daemon
and you won't get mail back.
In addition, it would be nice if you have lines beginning with
";strategy" that describe the algorithm you use.
3) Mail this file to "wms@iwarp.intel.com".
4) Within a few minutes you should get mail back telling you whether your
program assembled correctly or not. If it did assemble correctly,
sit back and wait; if not, make the change required and re-submit.
5) In an hour or so you should get more mail telling you how your program
performed against the current top 20 programs. If no news arrives in an
hour, don't worry; entries are put in a queue and run through the
tournament one at a time. A backlog may develop. Be patient.
If your program makes it onto the hill, you will get mail every time a
new program makes it onto the hill. If this is too much mail, you can use
";redcode quiet" when you first mail in your program; then you will only
get mail when you make it on the top 20 list or when you are knocked off.
Using ";redcode verbose" will give you even more mail; here you get mail
every time a new challenger arrives, even if they don't make it onto the
top 20 list.
Often programmers want to try out slight variations in their programs.
If you already have a program named "foo V1.0" on the hill, adding the
line ";kill foo" to a new program will automatically bump foo 1.0 off the
hill. Just ";kill" will remove all of your programs when you submit the
new one.
MORE ON KOTH COREWAR IMPLEMENTATION
Core size: 8000 instructions
Max processes: 8000 per program
Duration: After 80,000 cycles, a tie is declared.
Max entry length: 100 instructions
Programs are guaranteed a 100 instruction block (inclusive of their
warrior's instructions) without overlapping their opponent.
SAMPLE ENTRY:
;redcode
;name Dwarf
;author A. K. Dewdney
;strategy Throw DAT bombs around memory, hitting every 4th memory cell.
;strategy This program was presented in the first Corewar article.
bomb DAT #0
dwarf ADD #4, bomb
MOV bomb, @bomb
JMP dwarf
END dwarf ; Programs start at the first line unless
; an "END start" pseudo-op appears to indicate
; the first logical instruction. Also, nothing
; after the END instruction will be assembled.
Rule variants for "eXperimental" corewar:
The same as above but use ";redcode-x" to start your program.
Your program will be entered into a second tournament with slightly
different rules. The rules are:
- All addressing modes are allowed with all instructions.
- There is an additional addressing mode, called "postincrement". To use
it try an instruction like "mov >5,6".
- The maximum write distance is 250 instructions. That is, every time
your program tries to modify memory, the address is checked; if it is
more than 250 instructions from the process doing the modify, then
memory is left unchanged, but the instruction continues as normal.
- A tie is not declared until 150,000 cycles per program have elapsed.
KotH runs on any Unix system with an X windows interface. The source code
to KotH is available by email from William Shubert. Write to him at
(wms@iwarp.intel.com) for a copy or get it by anonymous FTP from
soda.berkeley.edu in the pub/corewar/systems directory (see Q12).
STORMKING.COM KOTH:
A second KotH server is installed at stormking.com. Send your warrior to
koth@stormking.com. Since this is an UUCP site, it may take a day before you
get results back. There are currently five separate hills that you can select
by starting your program with ;redcode, ;redcode-x ;redcode-icws,
;redcode-94, or ;redcode-94x. ;redcode and ;redcode-x select hills with
rules of the regular and experimental hills at intel.com (see above).
;redcode-icws sends your warrior to the ICWS-hill. Rules here follow that of
the annual ICWS tournament, in short:
Core size: 8192 instructions
Max processes: 64 per program
Duration: After 100,000 cycles, a tie is declared.
Max entry length: 300 instructions
;redcode-94 selects the experimental ICWS'94 (see Q 5 for more on this
proposed new standard). Core size, Max processes, etc. are identical to the
regular hills at stormking and intel.com.
;redcode-94x selects the experimental '94 or simply "Big Hill". Here the core
size is 55440, a number with many small factors, that might lead to more
complex warriors. Like the '94 hill, the '94x hill supports the ICWS'94
dialect. Here all parameters:
Core size: 55,440 instructions
Max processes: 10,000 per program
Duration: After 500,000 cycles, a tie is declared.
Max entry length: 200 instructions
All hills at stormking.com except for the x-hill run portable MARS, a
platform-independent corewar system available at soda (see Q12).
The contact person is for this server is Scott J. Ellentuch
(tuc@stormking.com). Please send all bug reports, inquiries, etc. to him and
me (stst@vuse.vanderbilt.edu).
----------------------------------------------------------------------
Q17: Is it DAT 0, 0 or DAT #0, #0? How do I compare to core?
A17: Core is initialized to DAT 0, 0. This is an "illegal" instruction
under ICWS'88 rules and strictly compliant assemblers (such as KotH)
will not let you write a DAT 0, 0 instruction - only DAT #0, #0. So
this begs the question, how to compare something to see if it is empty
core. The answer is, most likely the instruction before your first
instruction and the instruction after your last instruction are both
DAT 0, 0. You can use them, or any other likely unmodified instructions,
for comparison.
----------------------------------------------------------------------
Q18: How does SLT (Skip if Less Than) work?
A18: SLT gives some people trouble because of the way modular arithmetic
works. It is important to note that all negative numbers are converted
to positive numbers before a battles begins. Example: (-1) becomes
(M - 1) where M is the memory size.
Once you realize that all numbers are treated as positive, it is clear
what is meant by "less than". It should also be clear that no number is
less than zero.
----------------------------------------------------------------------
Q19: What does (expression or term of your choice) mean?
A19: Here is a selected glossary of terms. If you have a definition and/or
term you wish to see here, please send it to me.
(References to an X-like program mean that the term X is derived from the
specific program X and has become a generic term).
Bootstrapping - Strategy of copying the active portion of the program
away from the initial location, leaving a decoy behind and
making the relocated program as small as possible.
B-Scanners - Scanners which only recognize non-zero B-fields.
example add #10,scan
scan jmz example,10
C - Measure of speed, equal to one location per cycle. Speed of light.
CMP-Scanner - A Scanner which uses a CMP instruction to look for opponents.
example add step,scan
scan cmp 10,30
jmp attack
jmp example
step dat #20,#20
Color - Property of bombs making them visible to scanners, causing them
to attack useless locations, thus slowing them down.
example dat #100
Core-Clear - code that sequentially overwrites core with DAT instructions;
usually the last part of a program.
Decoys - Bogus or unused instructions meant to slow down Scanners.
Typically, DATs with non-zero B-fields.
DJN-Stream (also DJN-Train) - Using a DJN command to rapidly decrement core
locations.
example . . .
. . .
djn example,<4000
Dwarf - the prototypical small bomber.
Imp - Program which only uses the MOV instruction.
example MOV 0, 1
or
example MOV 0, 2
MOV 0, 2
Imp-Gate - A location in core which is bombed or decremented continuously
so that an Imp can not pass. Also used to describe the program-code
which maintains the gate.
example ...
...
SPL 0, <example
DAT <example, #0
Imp-Ring - A minimal Imp-Spiral.
d EQU (coresize+1)/3
A MOV 0,d ; copy self to B
B MOV 0,d ; copy self to C
C MOV 0,d ; copy self to A+1
Imp-Spiral - An Imp-like program with two or more processes supporting
each other. A three-point spiral, with six processes running in this
sequence:
d EQU (coresize+1)/3
A MOV 0,d ; copy self to B
B MOV 0,d ; copy self to C
C MOV 0,d ; copy self to A+1
A+1 MOV 0,d ; copy self to B+1
B+1 MOV 0,d ; copy self to C+1
C+1 MOV 0,d ; copy self to A+2
Incendiary Bomb - A type of Stun bomb which creates a SPL 0 carpet.
example SPL 0, 8
MOV -1, <-1
Mirror - see reflection
On-axis -
Off-axis - On-axis scanners compare two locations M/2 apart, where M
is the memory size. Off-axis scanners use some other separation.
Paper - A Paper-like program. One which replicates itself many times.
Part of the Scissors (beats) Paper (beats) Stone (beats Scissors) analogy.
Pit-Trapper - (also Slaver, Vampire). A program which enslaves another.
Usually accomplished by bombing with JMPs to a SPL 0 pit with an
optional core-clear routine.
Reflection - Copy of a program or program part, positioned to make
the active program invisible to a CMP-scanner.
Replicator - Generic for Paper. A program which makes many copies of
itself, each copy also making copies.
Self-Splitting - Strategy of amplifying the number of processes executing
a piece of code.
example SPL 0
loop ADD #10, example
MOV example, @example
JMP loop
Scanner - A program which searches through core for an opponent rather
than bombing blindly.
Scissors - A program designed to beat replicators, usually a (B-field
scanning) vampire. Part of the Paper-Scissors-Stone analogy.
Self-Repair - Ability of a program to fix it's own code after attack.
Slaver - see Pit-Trapper.
Stealth - Property of programs, or program parts, which are invisible
to scanners, accomplished by using zero B-fields and reflections.
Stone - A Stone-like program designed to be a small bomber. Part of the
Paper-Scissors-Stone analogy.
Stun - A type of bomb which makes the opponent multiply useless processes,
thus slowing it down. Example is referred to as a spl-jmp bomb.
example spl 0
jmp -1
Vampire - See Pit-Trapper.
----------------------------------------------------------------------
Q20: Other questions?
A20: Just ask in the rec.games.corewar newsgroup or contact me (address
below). If you are shy, check out the Core War archives on soda first to
see if your question has been answered before (see Q11).
----------------------------------------------------------------------
Additions/Corrections/etc. to this document are solicited.
The rec.games.corewar FAQ has been started by Mark Durham and is being
maintained by:
Stefan Strack, PhD stst@vuse.vanderbilt.edu
Dept. Pharmacology, 424 MRB stracks@vuctrvax.bitnet
Vanderbilt Univ. Medical Center Voice: +615-322-4890
Nashville, TN 37232-6600, USA FAX: +615-343-6532